std::sub_match
From Cppreference
| C++ Standard Library |
|---|
| Regular expressions library |
| Template:cpp/regex/sidebar content |
| std::sub_match |
| Template:cpp/regex/sub match/sidebar content |
| Defined in header <regex>
| ||
| template<
class BidirectionalIterator | (C++11 feature) | |
The class template sub_match is used by the regular expression engine to denote sequences of characters matched by marked sub-expressions.
| This section is incomplete |
Inherits std::pair<BidirectionalIterator, BidirectionalIterator>
Several specializations for common character sequence types are provided:
| Defined in header
<regex> | |
| Type | Definition |
| csub_match | sub_match<const char*> |
| wcsub_match | sub_match<const wchar_t*> |
| ssub_match | sub_match<std::string::const_iterator> |
| wssub_match | sub_match<std::wstring::const_iterator> |
Contents |
[edit] Member types
| Member type | Definition |
| iterator | BidirectionalIterator |
| value_type | std::iterator_traits<BidirectionalIterator>::value_type |
| difference_type | std::iterator_traits<BidirectionalIterator>::difference_type |
| string_type | std::basic_string<value_type> |
[edit] Member functions
| constructs the match object (public member function) | |
Observers | ||
| returns the length of the match, if any (public member function) | |
| cast to the underlying string type (public member function) | |
| returns the matched subsequence (public member function) | |
| compares matched subsequence (if any) (public member function) | |
Member objects | ||
| defines whether this match was successful (public member object) | |
[edit] Non-member functions
| This section is incomplete Reason: non-member functions |